<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <!-- TEMPLATE_MARKER: 2025-09-11-TA-FIX -->
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>虚拟货币查询工具</title>
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet">
    <link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css" rel="stylesheet">
    <link rel="stylesheet" href="/static/style.css">
    <style>
        /* 特定于index.html的自定义样式 */
        .main-container {
            max-width: 600px;
            margin-top: 50px;
        }
        
        .crypto-card {
            background: linear-gradient(135deg, #1e2a3a 0%, #2d3b50 100%);
            color: white;
            margin-top: 30px;
            border: none;
        }
        
        .card-header::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="75" cy="75" r="1" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
            opacity: 0.3;
        }
        
        .current-price {
            font-size: 3rem;
            font-weight: 800;
            margin-bottom: 15px;
            background: linear-gradient(135deg, #00c9ff 0%, #92fe9d 100%);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
        }
        
        .price-change {
            font-size: 1.2rem;
            padding: 8px 16px;
            border-radius: 25px;
            font-weight: 600;
            display: inline-block;
            margin-bottom: 20px;
        }
        
        .change-positive {
            background: rgba(0, 200, 83, 0.2);
            color: #00c853;
            border: 2px solid rgba(0, 200, 83, 0.3);
        }
        
        .change-negative {
            background: rgba(255, 55, 95, 0.2);
            color: #ff375f;
            border: 2px solid rgba(255, 55, 95, 0.3);
        }
        
        .additional-info {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 20px;
            padding: 0 20px 25px;
        }
        
        .info-item {
            text-align: center;
            padding: 15px;
            background: rgba(255, 255, 255, 0.05);
            border-radius: 12px;
            border: 1px solid rgba(255, 255, 255, 0.1);
        }
        
        .info-label {
            font-size: 0.8rem;
            opacity: 0.7;
            margin-bottom: 8px;
            text-transform: uppercase;
            letter-spacing: 1px;
        }
        
        .info-value {
            font-size: 1.1rem;
            font-weight: 600;
        }
        
        /* 多货币转换样式 */
        .currency-conversion {
            background: rgba(255, 255, 255, 0.95) !important;
            border: 1px solid rgba(0, 123, 255, 0.2);
        }
        
        .conversion-item {
            background: rgba(0, 123, 255, 0.05);
            border-radius: 6px;
            transition: all 0.3s ease;
        }
        
        .conversion-item:hover {
            background: rgba(0, 123, 255, 0.1);
            transform: scale(1.02);
        }
        
        .currency-label {
            font-size: 0.8rem;
            color: #6c757d;
            font-weight: 600;
            margin-bottom: 2px;
        }
        
        .currency-value {
            font-size: 0.95rem;
            color: #495057;
        }
        
        .search-form {
            padding: 30px;
        }
        
        .form-control {
            border-radius: 15px;
            border: 2px solid rgba(102, 126, 234, 0.2);
            padding: 15px 20px;
            font-size: 1.1rem;
            transition: all 0.3s ease;
        }
        
        .form-control:focus {
            border-color: #667eea;
            box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
        }
        
        .btn-search {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            border: none;
            border-radius: 15px;
            padding: 15px 30px;
            font-weight: 600;
            transition: all 0.3s ease;
        }
        
        .btn-search:hover {
            transform: translateY(-2px);
            box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
        }
        
        .error-alert {
            background: rgba(255, 55, 95, 0.1);
            border: 2px solid rgba(255, 55, 95, 0.3);
            color: #ff375f;
            border-radius: 15px;
            margin-top: 20px;
        }
        
        .last-updated {
            text-align: center;
            padding: 15px;
            font-size: 0.8rem;
            opacity: 0.6;
            border-top: 1px solid rgba(255, 255, 255, 0.1);
        }
        
        .loading {
            display: none;
            text-align: center;
            margin-top: 20px;
        }
        
        .spinner {
            border: 3px solid rgba(255, 255, 255, 0.3);
            border-radius: 50%;
            border-top: 3px solid #667eea;
            width: 40px;
            height: 40px;
            animation: spin 1s linear infinite;
            margin: 0 auto 15px;
        }
        
        @keyframes spin {
            0% { transform: rotate(0deg); }
            100% { transform: rotate(360deg); }
        }
        
        .examples {
            margin-top: 15px;
            font-size: 0.9rem;
            color: #6c757d;
        }
        
        .example-tag {
            display: inline-block;
            background: rgba(102, 126, 234, 0.1);
            color: #667eea;
            padding: 4px 8px;
            border-radius: 8px;
            margin: 2px;
            cursor: pointer;
            transition: all 0.2s ease;
        }
        
        .example-tag:hover {
            background: rgba(102, 126, 234, 0.2);
            transform: translateY(-1px);
        }
        
        /* 技术分析样式 */
        .technical-analysis-section {
            margin-top: 25px;
            padding: 25px 20px;
            border-top: 1px solid rgba(255, 255, 255, 0.1);
        }
        
        .section-header {
            text-align: center;
            margin-bottom: 20px;
        }
        
        .section-header h4 {
            margin: 0;
            color: #00c9ff;
            font-size: 1.2rem;
        }
        
        .main-indicators {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
            gap: 15px;
            margin-bottom: 20px;
        }
        
        .indicator-card {
            background: rgba(255, 255, 255, 0.08);
            border-radius: 12px;
            padding: 15px 10px;
            text-align: center;
            border: 1px solid rgba(255, 255, 255, 0.1);
            transition: all 0.3s ease;
        }
        
        .indicator-card:hover {
            background: rgba(255, 255, 255, 0.12);
            transform: translateY(-2px);
        }
        
        .indicator-name {
            font-size: 0.8rem;
            opacity: 0.8;
            margin-bottom: 8px;
            text-transform: uppercase;
            letter-spacing: 0.5px;
        }
        
        .indicator-value {
            font-size: 1.3rem;
            font-weight: 700;
            margin-bottom: 8px;
            color: #00c9ff;
        }
        
        .indicator-signal {
            font-size: 0.7rem;
            padding: 4px 8px;
            border-radius: 12px;
            font-weight: 600;
            text-transform: uppercase;
            letter-spacing: 0.5px;
        }
        
        .signal-bullish {
            background: rgba(0, 200, 83, 0.3);
            color: #00c853;
            border: 1px solid rgba(0, 200, 83, 0.5);
        }
        
        .signal-bearish {
            background: rgba(255, 55, 95, 0.3);
            color: #ff375f;
            border: 1px solid rgba(255, 55, 95, 0.5);
        }
        
        .signal-overbought {
            background: rgba(255, 152, 0, 0.3);
            color: #ff9800;
            border: 1px solid rgba(255, 152, 0, 0.5);
        }
        
        .signal-oversold {
            background: rgba(76, 175, 80, 0.3);
            color: #4caf50;
            border: 1px solid rgba(76, 175, 80, 0.5);
        }
        
        .signal-neutral {
            background: rgba(158, 158, 158, 0.3);
            color: #9e9e9e;
            border: 1px solid rgba(158, 158, 158, 0.5);
        }
        
        .detailed-indicators {
            background: rgba(255, 255, 255, 0.05);
            border-radius: 12px;
            padding: 15px;
            margin-bottom: 20px;
        }
        
        .detail-item {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 8px 0;
            border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        }
        
        .detail-item:last-child {
            border-bottom: none;
        }
        
        .detail-label {
            font-size: 0.9rem;
            opacity: 0.8;
        }
        
        .detail-value {
            font-weight: 600;
            color: #92fe9d;
        }
        
        .overall-signal {
            background: rgba(255, 255, 255, 0.08);
            border-radius: 12px;
            padding: 15px;
            text-align: center;
            margin-bottom: 15px;
        }
        
        .signal-title {
            font-size: 0.9rem;
            opacity: 0.8;
            margin-bottom: 10px;
        }
        
        .overall-signal-badge {
            display: inline-block;
            padding: 8px 16px;
            border-radius: 20px;
            font-weight: 600;
            font-size: 0.9rem;
            margin-bottom: 8px;
        }
        
        .signal-breakdown {
            font-size: 0.8rem;
            opacity: 0.7;
        }
        
        .analysis-info {
            text-align: center;
            padding-top: 10px;
            border-top: 1px solid rgba(255, 255, 255, 0.1);
        }
    </style>
</head>
<body>
    <div class="page-header text-center py-5">
        <h1 class="display-4 fw-bold text-white mb-3">虚拟货币查询工具</h1>
        <p class="lead text-white-50">实时查询加密货币价格、趋势和技术分析</p>
    </div>
    <div class="main-container">
        <div class="text-center mb-4">
            <h1 class="text-white mb-2">
                <i class="fas fa-coins me-2"></i>
                虚拟货币查询工具
            </h1>
            <p class="text-white-50">实时获取加密货币价格和市场数据</p>
        </div>
        
        <div class="card search-card card-hover mb-5">
            <form method="POST" class="search-form" id="searchForm">
                <div class="input-group mb-3">
                    <span class="input-group-text bg-transparent border-end-0">
                        <i class="fas fa-search text-primary"></i>
                    </span>
                    <input type="text" name="coin" class="form-control border-start-0 ps-0" 
                           placeholder="输入货币代码 (例如: BTC, ETH, BTC/USDT)" 
                           required id="coinInput" autocomplete="off">
                    <button class="btn btn-search" type="submit">
                        <i class="fas fa-chart-line me-2"></i>查询
                    </button>
                </div>
                
                <div class="examples">
                    <small>示例格式：</small>
                    <span class="example-tag" onclick="fillExample('BTC')">BTC</span>
                    <span class="example-tag" onclick="fillExample('ETH/USDT')">ETH/USDT</span>
                    <span class="example-tag" onclick="fillExample('ada')">ada</span>
                    <span class="example-tag" onclick="fillExample('SOL')">SOL</span>
                </div>
            </form>
        </div>
        
        <div class="loading" id="loading">
            <div class="spinner"></div>
            <p class="text-white">正在获取数据...</p>
        </div>

        {% if data %}
        <div class="card crypto-card card-hover shadow" id="cryptoCards">
            <div class="card-header bg-gradient">
                <div class="pair-info">
                    <h3 class="pair-symbol text-white">
                        <i class="fab fa-bitcoin"></i>
                        {{ data.symbol }}
                        {% if data.is_mock %}
                        <span class="badge bg-warning ms-2">
                            <i class="fas fa-exclamation-triangle"></i> 模拟
                        </span>
                        {% endif %}
                    </h3>
                    <p class="pair-name text-white-50">
                        {{ data.name }}
                        <span class="ms-2">
                            <i class="fas fa-database"></i> 数据源: {{ data.source }}
                        </span>
                    </p>
                </div>
            </div>
            
            <div class="price-section p-4">
                <div class="current-price fw-bold">{{ data.price_formatted }}</div>
                <div class="price-change {% if data.change_24h > 0 %}change-positive{% else %}change-negative{% endif %} shadow-sm">
                    <i class="fas {% if data.change_24h > 0 %}fa-arrow-up{% else %}fa-arrow-down{% endif %} me-1"></i>
                    {{ data.change_formatted }}
                </div>
            </div>
            
            <!-- 市场数据信息 -->
            <div class="market-info p-3 border-top">
                <div class="row g-3">
                    {% if data.high_24h and data.low_24h %}
                    <div class="col-6">
                        <div class="info-item card-hover p-2 rounded">
                            <div class="info-label"><i class="fas fa-arrow-up text-success me-1"></i>24小时最高</div>
                            <div class="info-value fw-bold">${{ "%.2f"|format(data.high_24h) }}</div>
                        </div>
                    </div>
                    <div class="col-6">
                        <div class="info-item card-hover p-2 rounded">
                            <div class="info-label"><i class="fas fa-arrow-down text-danger me-1"></i>24小时最低</div>
                            <div class="info-value fw-bold">${{ "%.2f"|format(data.low_24h) }}</div>
                        </div>
                    </div>
                    {% endif %}
                    
                    {% if data.volume %}
                    <div class="col-6">
                        <div class="info-item card-hover p-2 rounded">
                            <div class="info-label"><i class="fas fa-chart-bar text-info me-1"></i>24小时交易量</div>
                            <div class="info-value fw-bold">
                                {% if data.volume > 1000000000 %}
                                    ${{ "%.2f"|format(data.volume / 1000000000) }}B
                                {% elif data.volume > 1000000 %}
                                    ${{ "%.2f"|format(data.volume / 1000000) }}M
                                {% elif data.volume > 1000 %}
                                    ${{ "%.2f"|format(data.volume / 1000) }}K
                                {% else %}
                                    ${{ "%.2f"|format(data.volume) }}
                                {% endif %}
                            </div>
                        </div>
                    </div>
                    {% endif %}
                    
                    {% if data.market_cap %}
                    <div class="col-6">
                        <div class="info-item card-hover p-2 rounded">
                            <div class="info-label"><i class="fas fa-coins text-warning me-1"></i>市值</div>
                            <div class="info-value fw-bold">
                                {% if data.market_cap > 1000000000 %}
                                    ${{ "%.2f"|format(data.market_cap / 1000000000) }}B
                                {% elif data.market_cap > 1000000 %}
                                    ${{ "%.2f"|format(data.market_cap / 1000000) }}M
                                {% elif data.market_cap > 1000 %}
                                    ${{ "%.2f"|format(data.market_cap / 1000) }}K
                                {% else %}
                                    ${{ "%.2f"|format(data.market_cap) }}
                                {% endif %}
                            </div>
                        </div>
                    </div>
                    {% endif %}
                </div>
                
                <!-- 多货币转换显示 -->
                {% if data.price %}
                <div class="currency-conversion mt-3 p-3 bg-light rounded">
                    <div class="d-flex justify-content-between align-items-center mb-2">
                        <h6 class="mb-0"><i class="fas fa-exchange-alt me-2"></i>多货币显示</h6>
                        <div class="currency-selector">
                            <select id="currencySelector" class="form-select form-select-sm" style="width: auto;">
                                <option value="USD" selected>USD</option>
                                <option value="EUR">EUR</option>
                                <option value="CNY">CNY</option>
                            </select>
                        </div>
                    </div>
                    <div class="row g-2" id="currencyDisplay">
                        <div class="col-4">
                            <div class="conversion-item text-center p-2">
                                <div class="currency-label">USD</div>
                                <div class="currency-value fw-bold">${{ "%.2f"|format(data.price) }}</div>
                            </div>
                        </div>
                        <div class="col-4">
                            <div class="conversion-item text-center p-2">
                                <div class="currency-label">EUR</div>
                                <div class="currency-value fw-bold">€{{ "%.2f"|format(data.price * 0.85) }}</div>
                            </div>
                        </div>
                        <div class="col-4">
                            <div class="conversion-item text-center p-2">
                                <div class="currency-label">CNY</div>
                                <div class="currency-value fw-bold">¥{{ "%.2f"|format(data.price * 7.2) }}</div>
                            </div>
                        </div>
                    </div>
                    <div class="mt-2 text-center">
                        <small class="text-muted">
                            <i class="fas fa-info-circle me-1"></i>
                            汇率每5分钟更新一次
                        </small>
                    </div>
                </div>
                {% endif %}
            </div>
            
            {% if data.technical_analysis %}
            <!-- 技术分析区域 -->
            <div class="technical-analysis-section">
                <div class="section-header p-3 mb-3 bg-gradient rounded">
                    <h4 class="text-white mb-1"><i class="fas fa-chart-line me-2"></i>技术分析指标</h4>
                    <small class="text-white-50">基于最近30天数据计算</small>
                </div>
                
                <!-- 主要指标 -->
                <div class="main-indicators row g-3">
                    {% if data.technical_analysis.rsi %}
                    <div class="col-md-6 col-lg-3">
                        <div class="indicator-card card-hover">
                            <div class="indicator-name"><i class="fas fa-signal me-1"></i> RSI (14)</div>
                            <div class="indicator-value">{{ "%.2f"|format(data.technical_analysis.rsi) }}</div>
                            <div class="indicator-signal signal-{{ data.technical_analysis.signals.rsi if data.technical_analysis.signals.rsi else 'neutral' }}">
                                {% if data.technical_analysis.signals.rsi == 'overbought' %}<i class="fas fa-exclamation-circle me-1"></i>超买
                                {% elif data.technical_analysis.signals.rsi == 'oversold' %}<i class="fas fa-exclamation-circle me-1"></i>超卖
                                {% elif data.technical_analysis.signals.rsi == 'bullish' %}<i class="fas fa-arrow-up me-1"></i>看涨
                                {% elif data.technical_analysis.signals.rsi == 'bearish' %}<i class="fas fa-arrow-down me-1"></i>看跌
                                {% else %}<i class="fas fa-minus me-1"></i>中性{% endif %}
                            </div>
                        </div>
                    </div>
                    {% endif %}
                    
                    {% if data.technical_analysis.macd %}
                    <div class="col-md-6 col-lg-3">
                        <div class="indicator-card card-hover">
                            <div class="indicator-name"><i class="fas fa-wave-square me-1"></i> MACD</div>
                            <div class="indicator-value">{{ "%.2f"|format(data.technical_analysis.macd.histogram) }}</div>
                            <div class="indicator-signal signal-{{ data.technical_analysis.signals.macd if data.technical_analysis.signals.macd else 'neutral' }}">
                                {% if data.technical_analysis.signals.macd == 'bullish' %}<i class="fas fa-arrow-up me-1"></i>看涨
                                {% elif data.technical_analysis.signals.macd == 'bearish' %}<i class="fas fa-arrow-down me-1"></i>看跌
                                {% else %}<i class="fas fa-minus me-1"></i>中性{% endif %}
                            </div>
                        </div>
                    </div>
                    {% endif %}
                    
                    {% if data.technical_analysis.bollinger_bands %}
                    <div class="col-md-6 col-lg-3">
                        <div class="indicator-card card-hover">
                            <div class="indicator-name"><i class="fas fa-grip-lines me-1"></i> 布林带</div>
                            <div class="indicator-value">${{ "%.2f"|format(data.technical_analysis.bollinger_bands.middle) }}</div>
                            <div class="indicator-signal signal-neutral"><i class="fas fa-minus me-1"></i>中轨</div>
                        </div>
                    </div>
                    {% endif %}
                    
                    {% if data.technical_analysis.sma_20 %}
                    <div class="col-md-6 col-lg-3">
                        <div class="indicator-card card-hover">
                            <div class="indicator-name"><i class="fas fa-sliders-h me-1"></i> SMA (20)</div>
                            <div class="indicator-value">${{ "%.2f"|format(data.technical_analysis.sma_20) }}</div>
                            <div class="indicator-signal signal-neutral"><i class="fas fa-minus me-1"></i>均线</div>
                        </div>
                    </div>
                    {% endif %}
                </div>
                
                <!-- 详细指标 -->
                <div class="detailed-indicators">
                    <div class="row">
                        {% if data.technical_analysis.ema_12 %}
                        <div class="col-6">
                            <div class="detail-item">
                                <span class="detail-label">EMA (12):</span>
                                <span class="detail-value">${{ "%.2f"|format(data.technical_analysis.ema_12) }}</span>
                            </div>
                        </div>
                        {% endif %}
                        
                        {% if data.technical_analysis.ema_26 %}
                        <div class="col-6">
                            <div class="detail-item">
                                <span class="detail-label">EMA (26):</span>
                                <span class="detail-value">${{ "%.2f"|format(data.technical_analysis.ema_26) }}</span>
                            </div>
                        </div>
                        {% endif %}
                        
                        <!-- 已移除随机指标、威廉指标、商品通道指数和动量指标的显示 -->
                    </div>
                </div>
                
                <!-- 综合信号 -->
                <div class="overall-signal mt-4 card-hover p-3 rounded">
                    <div class="signal-title fw-bold"><i class="fas fa-chart-pie me-2"></i>综合交易信号</div>
                    <div class="signal-content mt-3">
                        {% set bullish_count = data.technical_analysis.signals.values() | select("equalto", "bullish") | list | length %}
                        {% set bearish_count = data.technical_analysis.signals.values() | select("equalto", "bearish") | list | length %}
                        {% set overbought_count = data.technical_analysis.signals.values() | select("equalto", "overbought") | list | length %}
                        {% set oversold_count = data.technical_analysis.signals.values() | select("equalto", "oversold") | list | length %}
                        
                        {% if bullish_count > bearish_count %}
                            <div class="overall-signal-badge signal-bullish shadow-sm">
                                <i class="fas fa-arrow-up me-1"></i>偏向看涨
                            </div>
                        {% elif bearish_count > bullish_count %}
                            <div class="overall-signal-badge signal-bearish shadow-sm">
                                <i class="fas fa-arrow-down me-1"></i>偏向看跌
                            </div>
                        {% else %}
                            <div class="overall-signal-badge signal-neutral shadow-sm">
                                <i class="fas fa-minus me-1"></i>中性
                            </div>
                        {% endif %}
                        
                        <div class="signal-breakdown">
                            看涨: {{ bullish_count }} | 看跌: {{ bearish_count }} 
                            {% if overbought_count > 0 %}| 超买: {{ overbought_count }}{% endif %}
                            {% if oversold_count > 0 %}| 超卖: {{ oversold_count }}{% endif %}
                        </div>
                    </div>
                </div>
                
                <!-- 性能信息 -->
                <div class="analysis-info">
                    <small class="text-muted">
                        <i class="fas fa-info-circle me-1"></i>
                        分析数据点: {{ data.technical_analysis.data_points_used }} | 
                        计算耗时: {{ "%.1f"|format(data.technical_analysis.calculation_time_ms) }}ms
                    </small>
                </div>
            </div>
            {% endif %}
            
            <div class="last-updated">
                <i class="fas fa-clock me-1"></i>
                最后更新: {{ data.last_updated }}
            </div>
        </div>
        {% endif %}

        {% if error %}
        <div class="alert error-alert">
            <i class="fas fa-exclamation-triangle me-2"></i>
            {{ error }}
        </div>
        {% endif %}
    </div>

    <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js"></script>
    <script>
        function fillExample(example) {
            document.getElementById('coinInput').value = example;
        }
        
        document.getElementById('searchForm').addEventListener('submit', function() {
            document.getElementById('loading').style.display = 'block';
        });
        
        // 自动隐藏加载动画
        window.addEventListener('load', function() {
            document.getElementById('loading').style.display = 'none';
            
            // 初始化货币选择器
            const currencySelector = document.getElementById('currencySelector');
            if (currencySelector) {
                currencySelector.addEventListener('change', function() {
                    updateCurrencyDisplay(this.value);
                });
            }
        });
        
        // 更新货币显示
        function updateCurrencyDisplay(selectedCurrency) {
            const currencyDisplay = document.getElementById('currencyDisplay');
            if (!currencyDisplay) return;
            
            // 添加更新动画
            currencyDisplay.classList.add('currency-display', 'updating');
            
            setTimeout(() => {
                // 高亮选中的货币
                const items = currencyDisplay.querySelectorAll('.conversion-item');
                items.forEach(item => {
                    const label = item.querySelector('.currency-label').textContent;
                    if (label === selectedCurrency) {
                        item.style.background = 'rgba(0, 123, 255, 0.2)';
                        item.style.border = '2px solid rgba(0, 123, 255, 0.5)';
                        item.style.transform = 'scale(1.05)';
                    } else {
                        item.style.background = 'rgba(0, 123, 255, 0.05)';
                        item.style.border = '1px solid rgba(0, 123, 255, 0.1)';
                        item.style.transform = 'scale(1)';
                    }
                });
                
                currencyDisplay.classList.remove('updating');
            }, 150);
        }
        
        // 格式化货币数值
        function formatCurrencyValue(value, currency) {
            const symbols = {
                'USD': '$',
                'EUR': '€',
                'CNY': '¥'
            };
            
            const symbol = symbols[currency] || currency;
            return `${symbol}${value.toFixed(2)}`;
        }
    </script>
    
    <footer class="text-center mt-5 mb-4">
        <div class="container">
            <div class="py-4 px-5 bg-white bg-opacity-20 rounded-pill d-inline-block shadow-lg border border-white border-opacity-25">
                <a href="https://github.com/Aci1998/crypto-price-checker" target="_blank" class="text-white text-decoration-none fs-4 fw-bold">
                    <i class="fab fa-github me-3 fs-3"></i> <span class="text-uppercase">GitHub 开源项目</span>
                </a>
            </div>
            <div class="mt-3">
                <small class="text-white-50">点击上方链接查看源代码</small>
            </div>
        </div>
    </footer>
</body>
</html>